# Filters added to this controller apply to all controllers in the application.
# Likewise, all the methods added will be available for all controllers.

class ApplicationController < ActionController::Base
  helper :all # include all helpers, all the time
  protect_from_forgery :secret => '12bc9c7f6e54b5cb021781da9d1d59ae'
  filter_parameter_logging :password
  
  include AuthenticatedSystem
  before_filter :set_default_title
  layout "blog"
  
  protected
  def title(text)
    title = text + " &mdash; experemental"
    instance_variable_set("@content_for_title", title)
  end
  
  def set_default_title
    instance_variable_set("@content_for_title", 'life &mdash; experemental')
  end

  def permission_denied
    render :file => "#{RAILS_ROOT}/public/404.html", :status => 404
  end
end
